Package com.cisco.pt.ipc.sim.impl
Class EnvironmentImpl
java.lang.Object
com.cisco.pt.ipc.impl.IPCObjectImpl
com.cisco.pt.ipc.sim.impl.EnvironmentImpl
- All Implemented Interfaces:
IPCObject,Environment
Information provided by the PKI file:
\class Environment
\brief An object in the Physical Workspace.
\example appWindow().getActiveWorkspace().getRootPhysicalObject().getEnvironment()
- Author:
- Auto-generated
-
Field Summary
Fields inherited from class com.cisco.pt.ipc.impl.IPCObjectImpl
accessMessage, ipcFactory, packetTracerSession -
Constructor Summary
ConstructorsConstructorDescriptionEnvironmentImpl(IPCFactory ipcFactory, PacketTracerSession packetTracerSession, IPCMessageLTV accessMessage) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddCustomEnvironment(String categoryId, String category, String id, String name, String metricUnit, String imperialUnit, String imperialFormula, String metricFormula) Information provided by the PKI file:addKeyframe(int timeInSeconds) Information provided by the PKI file:intInformation provided by the PKI file:voidInformation provided by the PKI file:Information provided by the PKI file:floatgetCumulativeContribution(String env, String devName) Information provided by the PKI file:intInformation provided by the PKI file:intgetElapsedTime(int lastTime) Information provided by the PKI file:getEnvironment(String env) Information provided by the PKI file:Information provided by the PKI file:intInformation provided by the PKI file:floatInformation provided by the PKI file:getKeyframeAt(int index) Information provided by the PKI file:intInformation provided by the PKI file:getKeyframeDataAsJSON(String envID) Information provided by the PKI file:intgetKeyframeIndexAtTime(int time) Information provided by the PKI file:getKeyframeTemplateAt(int index) Information provided by the PKI file:intInformation provided by the PKI file:floatgetMetricValue(String env) Information provided by the PKI file:intInformation provided by the PKI file:getNotes()intintInformation provided by the PKI file:intintInformation provided by the PKI file:Information provided by the PKI file:intInformation provided by the PKI file:floatInformation provided by the PKI file:floatInformation provided by the PKI file:Information provided by the PKI file:getValueWithUnit(String env) Information provided by the PKI file:floatInformation provided by the PKI file:booleanhasKeyframeAtTime(int time) Information provided by the PKI file:voidInformation provided by the PKI file:voidimportKeyframeTemplate(String file) Information provided by the PKI file:booleanInformation provided by the PKI file:booleanInformation provided by the PKI file:booleanInformation provided by the PKI file:booleanInformation provided by the PKI file:booleanInformation provided by the PKI file:booleanInformation provided by the PKI file:Information provided by the PKI file:voidInformation provided by the PKI file:voidremoveCumulativeContribution(String env, String devName) Information provided by the PKI file:voidInformation provided by the PKI file:booleanremoveEnvironmentKeyframe(String envID, int time) Information provided by the PKI file:voidremoveKeyframe(int index) Information provided by the PKI file:voidInformation provided by the PKI file:voidsetAllActive(String envId, boolean bOn) Information provided by the PKI file:voidsetAllInterpolate(String envId, boolean bOn) Information provided by the PKI file:voidInformation provided by the PKI file:voidsetAllMaxRate(String envId, float value) Information provided by the PKI file:voidInformation provided by the PKI file:voidsetAllMinRate(String envId, float value) Information provided by the PKI file:voidsetAllShow(String envId, boolean bOn) Information provided by the PKI file:voidsetAllTransference(String envId, float value) Information provided by the PKI file:voidsetContribution(String env, String devName, double rate, double limit, boolean bCumulative) Information provided by the PKI file:voidsetCurrentKeyTime(int t) voidsetEditMode(boolean bOn) voidvoidsetKeyframeActive(int currentKeyframeIndex, String envId, boolean bOn) Information provided by the PKI file:voidsetManualAdjustment(String env, float value) Information provided by the PKI file:voidsetNextKeyTime(int t) voidvoidsetRealTimeCombo(int s) voidsetRealTimeSetting(int s) voidsetShowNotes(boolean b) Information provided by the PKI file:voidsetSimTimeCombo(int s) voidsetSimTimeSetting(int s) voidsetThingTransferenceMultiplier(String env, String devName, float multiplier) Information provided by the PKI file:voidsetTimeInSeconds(int seconds) Information provided by the PKI file:voidsetTimeMultiplier(float x) Information provided by the PKI file:Methods inherited from class com.cisco.pt.ipc.impl.IPCObjectImpl
getAccessMessage, getClassName, getFactory, getObjectUUID, getPacketTracerSession, sendMessage, sendMessageWithReturn, translateToCommandStatusStringPairMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.cisco.pt.ipc.IPCObject
getAccessMessage, getClassName, getFactory, getObjectUUID, getPacketTracerSession
-
Constructor Details
-
EnvironmentImpl
public EnvironmentImpl(IPCFactory ipcFactory, PacketTracerSession packetTracerSession, IPCMessageLTV accessMessage)
-
-
Method Details
-
pauseTime
public void pauseTime()Information provided by the PKI file:
\brief Pauses the environment time.- Specified by:
pauseTimein interfaceEnvironment
-
resumeTime
public void resumeTime()Information provided by the PKI file:
\brief Resumes the environment time.- Specified by:
resumeTimein interfaceEnvironment
-
isTimeRunning
public boolean isTimeRunning()Information provided by the PKI file:
\brief Returns true if the environment time is running, false if paused. \return bool, true if the environment time is running, false if paused.- Specified by:
isTimeRunningin interfaceEnvironment- Returns:
- boolean Returns a boolean
-
getTimeInSeconds
public int getTimeInSeconds()Information provided by the PKI file:
\brief Returns the current environment runtime, in seconds. The value loops, so after 24 hours it resets to 0. \return int, the current environment runtime, in seconds.- Specified by:
getTimeInSecondsin interfaceEnvironment- Returns:
- int Returns a int
-
setTimeInSeconds
public void setTimeInSeconds(int seconds) Information provided by the PKI file:
\brief Sets the current environment time to the given time, in seconds. Time loops every 24 hours. \param seconds, the number of seconds to set the current environment time to. Time loops every 24 hours so the valid range is [0, 86400).- Specified by:
setTimeInSecondsin interfaceEnvironment- Parameters:
seconds- Takes in a parameter of seconds
-
getTimeMultiplier
public float getTimeMultiplier()Information provided by the PKI file:
\brief Multiplier used when calculating how much environment time passes each step, in seconds. \return float, the current environment runtime, in seconds.- Specified by:
getTimeMultiplierin interfaceEnvironment- Returns:
- float Returns a float
-
setTimeMultiplier
public void setTimeMultiplier(float x) Information provided by the PKI file:
\brief Sets the multiplier used when calculating how much environment time passes each step, in seconds. \param x, the number of seconds to set the step multipler as.- Specified by:
setTimeMultiplierin interfaceEnvironment- Parameters:
x- Takes in a parameter of x
-
getKeyframeCount
public int getKeyframeCount()Information provided by the PKI file:
\brief How many key frames are in the environment. \return int, the number of key frames in the environment.- Specified by:
getKeyframeCountin interfaceEnvironment- Returns:
- int Returns a int
-
getKeyframeAt
Information provided by the PKI file:
\brief How Returns a keyframe at a specified index. \param index, the keyframe to retrive. Range of [0, getKeyframeCount()). \return EnvironmentKeyframe, the keyframe at the given index.- Specified by:
getKeyframeAtin interfaceEnvironment- Parameters:
index- Takes in a parameter of index- Returns:
- EnvironmentKeyframe Returns a EnvironmentKeyframe
-
addKeyframe
Information provided by the PKI file:
\brief Adds a keyframe at the specified time and returns the new keyframe. \param time, the time to add the keyframe at, in seconds. Time loops every 24 hours so the valid range is [0, 86400). \return EnvironmentKeyframe, the keyframe added.- Specified by:
addKeyframein interfaceEnvironment- Parameters:
timeInSeconds- Takes in a parameter of timeInSeconds- Returns:
- EnvironmentKeyframe Returns a EnvironmentKeyframe
-
hasKeyframeAtTime
public boolean hasKeyframeAtTime(int time) Information provided by the PKI file:
\brief Returns if there is a keyframe at the given time. \param time, time in seconds to retrive the keyframe for. Time loops every 24 hours so the valid range is [0, 86400). \return bool, true if there was a keyframe, false if not.- Specified by:
hasKeyframeAtTimein interfaceEnvironment- Parameters:
time- Takes in a parameter of time- Returns:
- boolean Returns a boolean
-
getKeyframeIndexAtTime
public int getKeyframeIndexAtTime(int time) Information provided by the PKI file:
\brief Returns the index of a keyframe at the given time if one exists. \param time, time in seconds to retrive the keyframe index for. Time loops every 24 hours so the valid range is [0, 86400). \return int, value is the index if a match was found, -1 if not.- Specified by:
getKeyframeIndexAtTimein interfaceEnvironment- Parameters:
time- Takes in a parameter of time- Returns:
- int Returns a int
-
getStagingKeyframe
Information provided by the PKI file:
\brief Returns the staging keyframe. \return EnvironmentKeyframe, value is the staging keyframe.- Specified by:
getStagingKeyframein interfaceEnvironment- Returns:
- EnvironmentKeyframe Returns a EnvironmentKeyframe
-
addKeyframeFromStaging
public int addKeyframeFromStaging()Information provided by the PKI file:
\brief Adds a keyframe from staging. \return int, value is index of the keyframe after it gets added from staging.- Specified by:
addKeyframeFromStagingin interfaceEnvironment- Returns:
- int Returns a int
-
removeKeyframe
public void removeKeyframe(int index) Information provided by the PKI file:
\brief Removes the keyframe at the given index if the keyframe exists and isn't the start or end. \param index, index of the keyframe to remove. Range of (1, getKeyframeCount()-1).- Specified by:
removeKeyframein interfaceEnvironment- Parameters:
index- Takes in a parameter of index
-
getEnvironmentOptionsCount
public int getEnvironmentOptionsCount()Information provided by the PKI file:
\Returns how many environment value types there are. Categories are not included in the count, just the contents of all combined. \return int, value is the count of all environment values.- Specified by:
getEnvironmentOptionsCountin interfaceEnvironment- Returns:
- int Returns a int
-
getEnvironment
Information provided by the PKI file:
\brief Returns the options for a specified environment value type, like "CO" for carbon monoxide. \param env, name of the environment value to retrive, like "CO". \return EnvironmentOptions, value is the options for the specificed environment value type.- Specified by:
getEnvironmentin interfaceEnvironment- Parameters:
env- Takes in a parameter of env- Returns:
- EnvironmentOptions Returns a EnvironmentOptions
-
getEnvironmentKeys
Information provided by the PKI file:
\brief Returns a list of all the environment value types. \return vector<QString>, value is a list of all the environment value types.- Specified by:
getEnvironmentKeysin interfaceEnvironment- Returns:
- List<String> Returns a List<String>
-
getEnvironmentValue
Information provided by the PKI file:
\brief Returns the value for the specified environment property. \param env, name of the environment value to retrive, like "CO". \return float, value is the value of the environment value. If not found it will return -1, but that can also be a valued value.- Specified by:
getEnvironmentValuein interfaceEnvironment- Parameters:
env- Takes in a parameter of env- Returns:
- float Returns a float
-
getUnit
Information provided by the PKI file:
\brief Returns the unit used for the specified environment property. \param env, name of the environment value to retrive, like "CO". \return QString, value is the unit displayed for the environment value type, like "%" for gasses. The return can be an empty string.- Specified by:
getUnitin interfaceEnvironment- Parameters:
env- Takes in a parameter of env- Returns:
- String Returns a String
-
getValueWithUnit
Information provided by the PKI file:
\brief Returns a string combining the specified environment property and the display unit is uses. \param env, name of the environment value to retrive, like "CO". \return QString, value is a string combining the specified environment property and the display unit is uses.- Specified by:
getValueWithUnitin interfaceEnvironment- Parameters:
env- Takes in a parameter of env- Returns:
- String Returns a String
-
getMetricValue
Information provided by the PKI file:
\brief Returns the metric value for the given environment value. \param env, name of the environment value to retrive, like "CO". \return float, value is the metric value of the environment value.- Specified by:
getMetricValuein interfaceEnvironment- Parameters:
env- Takes in a parameter of env- Returns:
- float Returns a float
-
setCurrentKeyTime
public void setCurrentKeyTime(int t) - Specified by:
setCurrentKeyTimein interfaceEnvironment- Parameters:
t- Takes in a parameter of t
-
setNextKeyTime
public void setNextKeyTime(int t) - Specified by:
setNextKeyTimein interfaceEnvironment- Parameters:
t- Takes in a parameter of t
-
setEditMode
public void setEditMode(boolean bOn) - Specified by:
setEditModein interfaceEnvironment- Parameters:
bOn- Takes in a parameter of bOn
-
isEditMode
public boolean isEditMode()Information provided by the PKI file:
\brief Returns true if the environment editor window is in Edit mode. \return bool, value is true if the enviroment window is in Edit mode, false if it is in View mode.- Specified by:
isEditModein interfaceEnvironment- Returns:
- boolean Returns a boolean
-
exportToFile
public void exportToFile()Information provided by the PKI file:
\brief Starts the process for saving the environment window values to an xml file.- Specified by:
exportToFilein interfaceEnvironment
-
importFromFile
public void importFromFile()Information provided by the PKI file:
\brief Starts the save process for importing the environment window values from an xml file.- Specified by:
importFromFilein interfaceEnvironment
-
setAllActive
Information provided by the PKI file:
\brief Goes through all keyframes and staging keyframes and looks for keyframes with the given environment value type and sets them active/inactive. \param envId, name of the environment to check keyframes for. \param bOn, true if keyframes containing the value should be activated, false if deactivated.- Specified by:
setAllActivein interfaceEnvironment- Parameters:
envId- Takes in a parameter of envIdbOn- Takes in a parameter of bOn
-
setKeyframeActive
Information provided by the PKI file:
\brief Sets the specified keyframe to active and the environment value in it to be active. \param currentKeyframeIndex, index of the keyframe to set. \param envId, name of the environment to set for in the keyframe. \param bOn, true if keyframes containing the value should be activated, false if deactivated.- Specified by:
setKeyframeActivein interfaceEnvironment- Parameters:
currentKeyframeIndex- Takes in a parameter of currentKeyframeIndexenvId- Takes in a parameter of envIdbOn- Takes in a parameter of bOn
-
setAllShow
Information provided by the PKI file:
\brief Goes through all keyframes and staging keyframes and looks for keyframes with the given environment value type and sets the stored value for show. \param envId, name of the environment to check keyframes for. \param bOn, true if keyframes containing the value and the value should be shown, false if not shown.- Specified by:
setAllShowin interfaceEnvironment- Parameters:
envId- Takes in a parameter of envIdbOn- Takes in a parameter of bOn
-
setAllTransference
Information provided by the PKI file:
\brief Goes through all keyframes and staging keyframes and looks for keyframes with the given environment value type and sets the stored value for transference. \param envId, name of the environment to check keyframes for. \param value, transference to use.- Specified by:
setAllTransferencein interfaceEnvironment- Parameters:
envId- Takes in a parameter of envIdvalue- Takes in a parameter of value
-
setAllInterpolate
Information provided by the PKI file:
\brief Goes through all keyframes and staging keyframes and looks for keyframes with the given environment value type and sets the stored value for interpolate. \param envId, name of the environment to check keyframes for. \param bOn, true to use interpolation, false to not.- Specified by:
setAllInterpolatein interfaceEnvironment- Parameters:
envId- Takes in a parameter of envIdbOn- Takes in a parameter of bOn
-
setAllMin
Information provided by the PKI file:
\brief Goes through all keyframes and staging keyframes and looks for keyframes with the given environment value type and sets the stored value for min value allowed. \param envId, name of the environment to check keyframes for. \param value, min value allowed by the environment value.- Specified by:
setAllMinin interfaceEnvironment- Parameters:
envId- Takes in a parameter of envIdvalue- Takes in a parameter of value
-
setAllMax
Information provided by the PKI file:
\brief Goes through all keyframes and staging keyframes and looks for keyframes with the given environment value type and sets the stored value for max value allowed. \param envId, name of the environment to check keyframes for. \param value, max value allowed by the environment value.- Specified by:
setAllMaxin interfaceEnvironment- Parameters:
envId- Takes in a parameter of envIdvalue- Takes in a parameter of value
-
setAllMinRate
Information provided by the PKI file:
\brief Goes through all keyframes and staging keyframes and looks for keyframes with the given environment value type and sets the stored value for min rate allowed. \param envId, name of the environment to check keyframes for. \param value, min rate value used by the environment value.- Specified by:
setAllMinRatein interfaceEnvironment- Parameters:
envId- Takes in a parameter of envIdvalue- Takes in a parameter of value
-
setAllMaxRate
Information provided by the PKI file:
\brief Goes through all keyframes and staging keyframes and looks for keyframes with the given environment value type and sets the stored value for max rate allowed. \param envId, name of the environment to check keyframes for. \param value, max rate value used by the environment value.- Specified by:
setAllMaxRatein interfaceEnvironment- Parameters:
envId- Takes in a parameter of envIdvalue- Takes in a parameter of value
-
setManualAdjustment
Information provided by the PKI file:
\brief Sets the manual adjustment property of the given environment value type. \param env, the name of the environment value type to set the property for. Like "CO2". \param value, value to set the env property value with.- Specified by:
setManualAdjustmentin interfaceEnvironment- Parameters:
env- Takes in a parameter of envvalue- Takes in a parameter of value
-
getCumulativeContribution
Information provided by the PKI file:
\brief Retrives the cumulative contribution for a device and environment value type. \param env, name of the environment to read the value for. \param devName, device to find the environment value for. \return float, value is the cumulative contribution based on the params.- Specified by:
getCumulativeContributionin interfaceEnvironment- Parameters:
env- Takes in a parameter of envdevName- Takes in a parameter of devName- Returns:
- float Returns a float
-
setContribution
public void setContribution(String env, String devName, double rate, double limit, boolean bCumulative) Information provided by the PKI file:
\brief Sets the rate, limit and if it is cumulative properties for the environment value for the specified device. \param env, name of the environment value to set the values for. \param devName, device to set for. \param rate, rate to use. If 0 it wipes out all the values and doesn't set any of the values passed. \param limit, limit to use. \param bCumulative, true if it should be set to cumulative, false if not.- Specified by:
setContributionin interfaceEnvironment- Parameters:
env- Takes in a parameter of envdevName- Takes in a parameter of devNamerate- Takes in a parameter of ratelimit- Takes in a parameter of limitbCumulative- Takes in a parameter of bCumulative
-
removeCumulativeContribution
Information provided by the PKI file:
\brief Removes the cumulative contribution for the environment value and device pair. \param env, name of the environment value to remove for. \param devName, device to remove for.- Specified by:
removeCumulativeContributionin interfaceEnvironment- Parameters:
env- Takes in a parameter of envdevName- Takes in a parameter of devName
-
setThingTransferenceMultiplier
Information provided by the PKI file:
\brief Sets the thing transference multipler the environment value and device pair. \param env, name of the environment value to remove for. \param devName, device to remove for. \param multiplier, multiplier to store.- Specified by:
setThingTransferenceMultiplierin interfaceEnvironment- Parameters:
env- Takes in a parameter of envdevName- Takes in a parameter of devNamemultiplier- Takes in a parameter of multiplier
-
getTotalContributions
Information provided by the PKI file:
\brief Retrives the total contribution for all environment entries of the given environment value type. \param env, name of the environment to read the value for. \return float, value is the total contribution based of the given environment value type.- Specified by:
getTotalContributionsin interfaceEnvironment- Parameters:
env- Takes in a parameter of env- Returns:
- float Returns a float
-
getSimTimeSetting
public int getSimTimeSetting()Information provided by the PKI file:
\brief Retrives second value of the "Simulation Time Scale:". \return int, retun is the value of the second property of "Simulation Time Scale:".- Specified by:
getSimTimeSettingin interfaceEnvironment- Returns:
- int Returns a int
-
getRealTimeSetting
public int getRealTimeSetting()Information provided by the PKI file:
\brief Retrives first value of the "Simulation Time Scale:". \return int, retun is the value of the first property of "Simulation Time Scale:".- Specified by:
getRealTimeSettingin interfaceEnvironment- Returns:
- int Returns a int
-
getSimTimeCombo
public int getSimTimeCombo()- Specified by:
getSimTimeComboin interfaceEnvironment- Returns:
- int Returns a int
-
getRealTimeCombo
public int getRealTimeCombo()- Specified by:
getRealTimeComboin interfaceEnvironment- Returns:
- int Returns a int
-
setSimTimeSetting
public void setSimTimeSetting(int s) - Specified by:
setSimTimeSettingin interfaceEnvironment- Parameters:
s- Takes in a parameter of s
-
setRealTimeSetting
public void setRealTimeSetting(int s) - Specified by:
setRealTimeSettingin interfaceEnvironment- Parameters:
s- Takes in a parameter of s
-
setSimTimeCombo
public void setSimTimeCombo(int s) - Specified by:
setSimTimeComboin interfaceEnvironment- Parameters:
s- Takes in a parameter of s
-
setRealTimeCombo
public void setRealTimeCombo(int s) - Specified by:
setRealTimeComboin interfaceEnvironment- Parameters:
s- Takes in a parameter of s
-
isUsingMetric
public boolean isUsingMetric()Information provided by the PKI file:
\brief Returns if the environment is using the metric system or imperial. \return bool, retun is true if the environment it set to use the metric system, false for imperial.- Specified by:
isUsingMetricin interfaceEnvironment- Returns:
- boolean Returns a boolean
-
getNotes
- Specified by:
getNotesin interfaceEnvironment- Returns:
- String Returns a String
-
setNotes
- Specified by:
setNotesin interfaceEnvironment- Parameters:
s- Takes in a parameter of s
-
isShowNotes
public boolean isShowNotes()Information provided by the PKI file:
\brief Returns if notes are set to show in the environment advanced options window. \return bool, retun is true if notes are set to show, false if set to hidden.- Specified by:
isShowNotesin interfaceEnvironment- Returns:
- boolean Returns a boolean
-
setShowNotes
public void setShowNotes(boolean b) Information provided by the PKI file:
\brief Sets the environment window property for whether notes should be shown in the advanced window. \param b, true to set notes to show when advanced options are viewied, false if they should be hidden.- Specified by:
setShowNotesin interfaceEnvironment- Parameters:
b- Takes in a parameter of b
-
isEditingLocked
public boolean isEditingLocked()Information provided by the PKI file:
\brief Returns if the environment editing window has been locked by interace locking option. \return bool, retun is true if the environment window is locked, false if not.- Specified by:
isEditingLockedin interfaceEnvironment- Returns:
- boolean Returns a boolean
-
addCustomEnvironment
public void addCustomEnvironment(String categoryId, String category, String id, String name, String metricUnit, String imperialUnit, String imperialFormula, String metricFormula) Information provided by the PKI file:
\brief Adds a custom environment value type to the environment. \param categoryId, category to add the value to, like "Radiation" or "Other". \param category, category to add, make it the same as categoryId. \param id, name of the environment value. Like "Sweetness" \param name, name to display in the editor window for the environment value. \param metricUnit, metric unit to display when display the value is in metric units. \param imperialUnit, imperial unit to display when value is in imperial units. \param imperialFormula, conversion formula to convert from- Specified by:
addCustomEnvironmentin interfaceEnvironment- Parameters:
categoryId- Takes in a parameter of categoryIdcategory- Takes in a parameter of categoryid- Takes in a parameter of idname- Takes in a parameter of namemetricUnit- Takes in a parameter of metricUnitimperialUnit- Takes in a parameter of imperialUnitimperialFormula- Takes in a parameter of imperialFormulametricFormula- Takes in a parameter of metricFormula
-
removeCustomEnvironment
Information provided by the PKI file:
\brief Removes a custom environment value type from the environment. This is only for custom properties, not for included properties like "CO2". \param env, name of the environment value. Like "Sweetness"- Specified by:
removeCustomEnvironmentin interfaceEnvironment- Parameters:
env- Takes in a parameter of env
-
isCustomEnvironment
Information provided by the PKI file:
\brief Returns true if the environment value is a custom environment value. \return bool, return is true if the environment exists and is a custom property or doesn't exist, false if it is not custom.- Specified by:
isCustomEnvironmentin interfaceEnvironment- Parameters:
env- Takes in a parameter of env- Returns:
- boolean Returns a boolean
-
getNextKeyTime
public int getNextKeyTime()Information provided by the PKI file:
\brief Debugging tool for getting the next keyframe time. \return int, return is the next keyframe time.- Specified by:
getNextKeyTimein interfaceEnvironment- Returns:
- int Returns a int
-
getCurrentKeyTime
public int getCurrentKeyTime()Information provided by the PKI file:
\brief Debugging tool for getting the current keyframe time. \return int, return is the current keyframe time.- Specified by:
getCurrentKeyTimein interfaceEnvironment- Returns:
- int Returns a int
-
getElapsedTime
public int getElapsedTime(int lastTime) Information provided by the PKI file:
\brief Returns the time difference between the given time and the current environment time, in seconds. \param lastTime, time to subtract from the current time to find the difference. \return int, return is the time difference between the current time and the given time.- Specified by:
getElapsedTimein interfaceEnvironment- Parameters:
lastTime- Takes in a parameter of lastTime- Returns:
- int Returns a int
-
getKeyframeTemplateCount
public int getKeyframeTemplateCount()Information provided by the PKI file:
\brief Returns how many default keyframe categores there are in the "Defaults:" section of the environment window when setting up advanced keyframes. \return int, return is how many default keyframe categores there are in the "Defaults:" section of the environment window when setting up advanced keyframes.- Specified by:
getKeyframeTemplateCountin interfaceEnvironment- Returns:
- int Returns a int
-
getKeyframeTemplateAt
Information provided by the PKI file:
\brief Returns the default keyframe template name at the given index. \param index, index of the template to retrive. Range (0, getKeyFrameTemplateCount()) \return QString, return is the default keyframe template name at the given index if it exists, crash if it doesn't.- Specified by:
getKeyframeTemplateAtin interfaceEnvironment- Parameters:
index- Takes in a parameter of index- Returns:
- String Returns a String
-
importKeyframeTemplate
Information provided by the PKI file:
\brief Starts importing a default keyframe template. \param file, the name of the template to import. Like "Blank.xml". \return QString, return is the default keyframe template name at the given index if it exists, crash if it doesn't.- Specified by:
importKeyframeTemplatein interfaceEnvironment- Parameters:
file- Takes in a parameter of file
-
parentEnvironment
Information provided by the PKI file:
\brief Returns the parent environment. \return Environment, return is the parent environment if it exists, null if not.- Specified by:
parentEnvironmentin interfaceEnvironment- Returns:
- Environment Returns a Environment
-
setGraphEnvironment
- Specified by:
setGraphEnvironmentin interfaceEnvironment- Parameters:
env- Takes in a parameter of env
-
getGraphEnvironment
- Specified by:
getGraphEnvironmentin interfaceEnvironment- Returns:
- String Returns a String
-
getVolume
public float getVolume()Information provided by the PKI file:
\brief Returns the total volume of the object that contains the environment. \return float, return is the total volume of the object that contains the environment.- Specified by:
getVolumein interfaceEnvironment- Returns:
- float Returns a float
-
getChangesAsJSON
Information provided by the PKI file:
\brief Returns change information as JSON data. \return QString, return is the change information as JSON data.- Specified by:
getChangesAsJSONin interfaceEnvironment- Returns:
- String Returns a String
-
getKeyframeDataAsJSON
Information provided by the PKI file:
\brief Returns keyframes with the given environment value as JSON data. \param envID, the environment variable type to get the information for. \return QString, return is the keyframes' information for the given environment value as JSON data.- Specified by:
getKeyframeDataAsJSONin interfaceEnvironment- Parameters:
envID- Takes in a parameter of envID- Returns:
- String Returns a String
-
removeEnvironmentKeyframe
Information provided by the PKI file:
\brief Removes the environment keyframe at the given time if it has the given environment variable type and it isn't the start or end keyframe. \param envID, the environment variable type that must be in the specified keyframe time for it to be removed. \param time, the environment time of the keyframe to remove. \return bool, return is true a keyframe was removed, false if not.- Specified by:
removeEnvironmentKeyframein interfaceEnvironment- Parameters:
envID- Takes in a parameter of envIDtime- Takes in a parameter of time- Returns:
- boolean Returns a boolean
-